FROM zhaotao/base-centos7

RUN	\
	# jdkDownloadUrl=http://download.oracle.com/otn-pub/java/jdk/8u181-b13/96a7b8442fe848ef90c96a2fad6ed6d1/jdk-8u181-linux-x64.rpm; \
	jdkDownloadUrl=http://zhaotao.vip/jdk-8u181-linux-x64.rpm; \
	jdkFileName=jdk.rpm; \
	yum install -y wget; \
	wget -O $jdkFileName --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" $jdkDownloadUrl; \
	rpm -ivh $jdkFileName; \
	rm -rf $jdkFileName; \
	yum remove -y wget; \
	yum clean all

ENV JAVA_HOME=/usr/java/jdk1.8.0_181-amd64 \
        CLASSPATH=$JAVA_HOME/lib:$JAVA_HOME/jre/lib \
        PATH=$PATH:$JAVA_HOME/bin:$JAVA_HOME/jre/bin
